#!usr/bin/env python
# -*- coding:utf-8 -*-
"""
ajax 请求的ajax连接在这里配置
"""
from django.urls import path
from django.views.decorators.csrf import csrf_exempt
from .api_view import Upload, Delete, GetArticleById, \
    UserView, Comments, Article, notice, article_list

urlpatterns = [
    path('query/', GetArticleById.as_view(), name="query-article-id-view"),
    path('delete/', Delete.as_view(), name='delete-article-view'),
    path('upload/', csrf_exempt(Upload.as_view()), name='upload-view'),
    # 查询个人资料
    path('user-info/<slug:author_name>', UserView.as_view()),
    # 评论树查询
    path('comments/', Comments.as_view()),
    # 首页文章
    path('index-art', Article.as_view()),
    path('notice/', notice),
    path('article_list/', article_list),
]
